package com.xyebank.ledger.service.common;

import com.xyebank.ledger.enums.LedgerJobType;

import java.util.List;

/**
 * 将原始台帐到标准台帐入库　处理业务接口
 * @param <A>　application　申请
 * @param <P>  payment　放款
 * @param <R> repayment 还款
 */
public interface UnionService<A, P, R>  {

    /**
     * 如标准T1台帐　申请库
     * @param fromIdx
     * @param list
     * @param jobType
     * @return
     */
    Integer dealApplication(Integer fromIdx, List<A> list, LedgerJobType jobType);

    /**
     * 如标准T1台帐　放款
     * @param fromIdx
     * @param list
     * @param jobType
     * @return
     */
    Integer dealPayment(Integer fromIdx, List<P> list, LedgerJobType jobType);

    /**
     * 入标准T1台帐　还款
     * @param fromIdx
     * @param list
     * @param jobType
     * @return
     */
    Integer dealRePayment(Integer fromIdx, List<R> list, LedgerJobType jobType);

}
